var status = -1;
var selectionLog = [];

function start() {
    action(1, 0, 0)
}

function action(d, c, b) {
    if (status == 0 && d == 0) {
        im.dispose();
        return
    }(d == 1) ? status++ : status--;
    selectionLog[status] = b;
    var a = -1;
    if (status <= a++) {
        im.dispose()
    } else {
        if (status === a++) {
            im.fieldEffect_PlayFieldSound("advStory/Buff7", 100);
            im.curNodeEventEnd(true);
            im.setInGameDirectionMode(true, true, true);
            im.inGameDirectionEvent_AskAnswerTime(500)
        } else {
            if (status === a++) {
                im.inGameDirectionEvent_AskAnswerTime(500);
                im.effect_REPEAT("Effect/Direction13.img/effect/zero/base/0", 1, 1, 1, 0, 0)
            } else {
                if (status === a++) {
                    im.inGameDirectionEvent_AskAnswerTime(1000);
                    im.effect_REPEAT("Effect/Direction13.img/effect/zero/displeased/0", 1, 1, 1, 0, 0)
                } else {
                    if (status === a++) {
                        im.inGameDirectionEvent_AskAnswerTime(500);
                        im.effect_REPEAT("Effect/Direction13.img/effect/zero/displeased/0", 1, 0, 0, 0, 0)
                    } else {
                        if (status === a++) {
                            im.inGameDirectionEvent_AskAnswerTime(500)
                        } else {
                            if (status === a++) {
                                im.inGameDirectionEvent_AskAnswerTime(1000);
                                im.effect_REPEAT("Effect/Direction13.img/effect/zero/handshake/0", 1, 1, 1, 0, 0)
                            } else {
                                if (status === a++) {
                                    im.inGameDirectionEvent_AskAnswerTime(500);
                                    im.effect_REPEAT("Effect/Direction13.img/effect/zero/handshake/0", 1, 0, 0, 0, 0)
                                } else {
                                    if (status === a++) {
                                        im.inGameDirectionEvent_AskAnswerTime(500)
                                    } else {
                                        if (status === a++) {
                                            im.inGameDirectionEvent_AskAnswerTime(1000);
                                            im.effect_REPEAT("Effect/Direction13.img/effect/zero/sining/0", 1, 1, 1, 0, 0)
                                        } else {
                                            if (status === a++) {
                                                im.inGameDirectionEvent_AskAnswerTime(500);
                                                im.effect_REPEAT("Effect/Direction13.img/effect/zero/sining/0", 1, 0, 0, 0, 0)
                                            } else {
                                                if (status === a++) {
                                                    im.inGameDirectionEvent_AskAnswerTime(500)
                                                } else {
                                                    if (status === a++) {
                                                        im.inGameDirectionEvent_AskAnswerTime(1000);
                                                        im.effect_REPEAT("Effect/Direction13.img/effect/zero/threat/0", 1, 1, 1, 0, 0)
                                                    } else {
                                                        if (status === a++) {
                                                            im.inGameDirectionEvent_AskAnswerTime(500);
                                                            im.effect_REPEAT("Effect/Direction13.img/effect/zero/threat/0", 1, 0, 0, 0, 0)
                                                        } else {
                                                            if (status === a++) {
                                                                im.sendNormalTalk("回忆碎片……真的能看到很多回忆。从我们第一次见面……然后前往神木村，阿里安特，射手村，武陵……还有其他村子。", 41, 2400005, false, true);
                                                                im.effect_REPEAT("Effect/Direction13.img/effect/zero/base/0", 1, 0, 0, 0, 0)
                                                            } else {
                                                                if (status === a++) {
                                                                    im.sendNormalTalk("嗯，期间发生过很多有趣的事情……", 41, 2400006, true, true)
                                                                } else {
                                                                    if (status === a++) {
                                                                        im.sendNormalTalk("…………", 41, 2400005, true, true)
                                                                    } else {
                                                                        if (status === a++) {
                                                                            im.sendNormalTalk("#face10#怎么在这其中找出不洁者呢？这里……只有快乐的回忆啊……", 41, 2400005, true, true)
                                                                        } else {
                                                                            if (status === a++) {
                                                                                im.sendNormalTalk("…………", 41, 2400006, true, true)
                                                                            } else {
                                                                                if (status === a++) {
                                                                                    im.forceStartQuest(40712, "1");
                                                                                    im.inGameDirectionEvent_AskAnswerTime(500)
                                                                                } else {
                                                                                    if (status === a++) {
                                                                                        im.setInGameDirectionMode(false, true, false);
                                                                                        im.dispose()
                                                                                    }
                                                                                }
                                                                            }
                                                                        }
                                                                    }
                                                                }
                                                            }
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
};